package com.feijie.proxy_demo.CGLIB.service;

/**
 * @program: proxy_demo
 * @description: 服务层实现类
 * @author: 作者
 * @create: 2022-03-11 11:17
 */
public class HelloService {

    public HelloService() {
        System.out.println("HelloService构造");
    }

    /**
     * 该方法不能被子类覆盖, Cglib是无法代理final修饰的方法的
     */
    final public String sayOthers(String name) {
        System.out.println("HelloService:sayOthers>>"+name);
        return null;
    }

    public void sayHello() {
        System.out.println("HelloService:sayHello");
    }

}
